When placing networks in _createSection, we were taking in
consideration that _activeNetwork is always first, by adding 1,
but then kept this offset also for networks following it (normally,
all of them, since _activeNetwork is also the most recently used),
that instead should not be affected by the movement.
This resulted in the menu showing 4 networks + More... instead of
5.
https://bugzilla.gnome.org/show_bug.cgi?id=664124
for(let j = 0; j < this._networks.length; j++) {
let apObj = this._networks[j];
- if (apObj == this._activeNetwork)
+ if (apObj == this._activeNetwork) {
+ activeOffset--;
continue;
+ }
this._createNetworkItem(apObj, j + activeOffset);
}